
public class LoginManager 
{
	private static AVL<String, User> tree;
	
	public void add(String type, String name, String username, String password)
	{
		if(type.equalsIgnoreCase("admin"))
			tree.insert(username, new Admin(name, username, password));
		else if(type.equalsIgnoreCase("instructor"))
			tree.insert(username, new Instructor(name, username, password));
		else
			tree.insert(username, new Student(name, username, password));
	}
	
	public User find(String username)
	{
		return tree.find(username);
	}
	
	public void changeStatus(String username)
	{
		tree.changeStatus(username);
	}
	
}
